package com.sangeng.controller;

import com.sangeng.entity.ResponseResult;
import com.sangeng.entity.User;
import com.sangeng.service.GlcAuthService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("auth")
public class GlcAuthController {

    @Autowired
    private GlcAuthService glcAuthService;

    @PostMapping("login")
    public ResponseResult login(@RequestBody User user) {

        return glcAuthService.login(user);
    }

}
